home *** CD-ROM | disk | FTP | other *** search
/ Magazyn Exec 3 / CD_Magazyn_EXEC_nr_3.iso / Gry / Tales of Tamar Demo.lha / talesdemo1 / ToT-Install < prev    next >
Text File  |  2000-07-21  |  5KB  |  155 lines

  1. ;$VER: ToT-Install (2000-07-05)
  2. ;Sebastian Huebner <cyco@baud.de>
  3.  
  4. ;check for installer version >=44 (OS3.5))
  5. (set #instver (/ @installer-version 65536))
  6. (if (>= #instver 44)
  7.     (
  8.       (effect "lower_right" "radial" $AA0000 $0000AA)
  9.       (showmedia "symbol" "Goodies/Title.iff" "upper_left" "none" 0)
  10.     )
  11. )
  12. ;~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  13. ;~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  14. ;~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  15.  
  16.  
  17. (set #totversion "Demo 0.29 R1")
  18. (set #totdirname "TalesDemo1" )
  19. (set #totassign  "ToTDemo1" )
  20. (set #deletedatafiles "(DEMO1_TCPIPReq.dat|DEMO1_TCPIPReq.RAWB)")
  21.  
  22.  
  23. ;~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  24. ;~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  25. ;~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  26. ; altes assign vorhanden? wenn nicht: "games:" vorhanden?
  27. (set #oldplace (getassign #totassign))
  28. (set #games    (getassign "games"   ))
  29. (if (and (<> "" #oldplace) (exists #oldplace))
  30.     ( (set #oldassignfound 1) (set @default-dest (pathonly #oldplace)) )
  31.     (if (and (<> "" #games) (exists #games))
  32.         (set @default-dest "Games:")
  33.     )
  34. )
  35.  
  36. (complete 0)
  37.  
  38. ;~~~~~~~~~~~~~~~~~~Englische Texte~~~~~~~~~~~~~~~~~~
  39.  
  40. (set #introduction
  41.   (cat "\nWelcome to the Installation of\n\nT A L E S\nO F\nT A M A R\n\n\n\nVersion: "
  42.        #totversion "\n\nhttp://www.tamar.net\nMartin Wolf <eternity@pride.de>"))
  43.  
  44. (set #ask-path (cat "Where should the directory \"" #totdirname "\" be created?\n"
  45.                     "An existing directory will be used."
  46.                ))
  47. (set #ask-path-help (cat "A new directory \"" #totdirname
  48.                          "\" will be created or an existing one will be used."))
  49. (set #ask-assign (cat "Should the assign \"" #totassign ":\" be added to your "
  50.                       "\"S:user-startup\"?"))
  51. (set #ask-assign-help (cat "The assign \"" #totassign ":\" can be added to your "
  52.                            "\"S:user-startup\".\n\n"
  53.                            "Because it is needed by " @app-name ", "
  54.                            "you should really do this. Otherwise you have to "
  55.                            "perform the addition by hand:\n\n   "
  56.                            ))
  57. (set #fileatplace (cat "Unable to create new directory:"
  58.                        "A file exists at that position ") )
  59.  
  60. (set #goodbye "\n\n\n\nGoodbye and have fun with Tales of Tamar!")
  61.  
  62. ;~~~~~~~~~~~~~~~~~~Deutsche Texte~~~~~~~~~~~~~~~~~~
  63.  
  64. (if (= @language "deutsch")
  65.  (
  66.   (set #introduction
  67.     (cat "\nWillkommen zur Installation von\n\nT A L E S\nO F\nT A M A R\n\n\n\nVersion: "
  68.          #totversion "\n\nhttp://www.tamar.net\nMartin Wolf <eternity@pride.de>"))
  69.  
  70.   (set #ask-path (cat "Wo soll das Verzeichnis \"" #totdirname "\" angelegt werden?\n"
  71.                       "Ein schon existierendes Verzeichnis wird weiter benutzt."
  72.                  ))
  73.   (set #ask-path-help (cat "A neues Verzeichnis \"" #totdirname
  74.                            "\" wird erstellt oder ein bereits vorhandenes weiter benutzt."))
  75. (set #ask-assign (cat "Soll die Zuweisung \"" #totassign ":\" zu Ihrer "
  76.                       "\"S:user-startup\" hinzugefügt werden?"))
  77. (set #ask-assign-help (cat "Die Zuweisung \"" #totassign ":\" kann zu Ihrer "
  78.                            "\"S:user-startup\" hinzugefügt werden.\n\n"
  79.                            "Da die Zuweisung von " @app-name " benötigt wird, "
  80.                            "sollten Sie die Ergänzung zulassen, andernfalls müssen sie "
  81.                            "diese per Hand durchführen:\n\n   "
  82.                            ))
  83.   (set #fileatplace (cat "Kann neues Verzeichnis nicht erstellen:"
  84.                          "Eine Datei befindet sich an der Position ") )
  85.  
  86.   (set #goodbye "\n\n\n\nViel Spaß mit Tales of Tamar!")
  87.  )
  88. )
  89.  
  90. ;~~~~~~~~~~~~~~~~~~Installation~~~~~~~~~~~~~~~~~~
  91.  
  92. (complete 1)
  93.  
  94. ; introduction
  95. (message #introduction (all))
  96.  
  97. (complete 10)
  98.  
  99. ;choose user level
  100. (welcome)
  101.  
  102. (complete 20)
  103.  
  104.  
  105. ; wo installieren?
  106. (set #totpath (askdir (prompt #ask-path) (help #ask-path-help)
  107.                       (default @default-dest))
  108. )
  109.  
  110. ; tot-verzeichnis anhaengen
  111. (set #totpath (tackon #totpath #totdirname))
  112.  
  113. (complete 30)
  114.  
  115. ; platz schon belegt oder alte schublade vorhanden?
  116. (set #checkplace (exists #totpath))
  117. (if (= #checkplace 1)
  118.     (abort (cat #fileatplace #totpath))
  119. )
  120.  
  121. (complete 50)
  122.  
  123. ; evtl. alte files loeschen, die nicht mit neuen ueberschrieben werden
  124. (if (= 2 #checkplace)
  125.     (if #deletedatafiles
  126.         (foreach (tackon #totpath "data")
  127.                  #deletedatafiles
  128.                  (delete (tackon (tackon #totpath "data") @each-name)
  129.                          (prompt "") (help ""))
  130.         )
  131.     )
  132. )
  133.  
  134. (complete 70)
  135.  
  136. ; alles ausser #?install#? kopieren (wenn noetig: neues Verzeichnis)
  137. (copyfiles (prompt "") (help "") (source "") (dest #totpath)
  138.            (pattern "~(#?install#?)") (infos) (noposition)
  139. )
  140.  
  141. (complete 90)
  142.  
  143. ; assign in die user-startup und auch gleich aktivieren
  144. (set #assigntext (cat "Assign \"" #totassign ":\" \"" #totpath "\""))
  145. (startup @app-name (prompt #ask-assign)
  146.                    (help (cat #ask-assign-help #assigntext))
  147.          (command #assigntext))
  148. (makeassign #totassign #totpath)
  149.  
  150. (complete 100)
  151.  
  152. ; und weg...
  153. (set @default-dest #totpath)
  154. (exit #goodbye)
  155.